/*

	CPositionalLight.h
	
	Implementation of the light source interface
	holding only a position. Lights is emitted to
	all sides.
	
	Written by Sigurd Suhm 2009

*/

#ifndef _CPOSITIONALLIGHT_H
#define _CPOSITIONALLIGHT_H

// Includes
#include "ILightSource.h"
#include "Vector.h"			// Vector classes header

namespace EraAstral
{
	namespace graphics
	{
		class PositionalLight : public ILightSource
		{
			private:
				// Light position
				Vector3		*m_position;
				
			public:
				// Default constructor
				PositionalLight(core::SceneManager *sceneManager);
				// Default destructor
				~PositionalLight();
				
				// Commits light changes to OpenGL
				void	Commit();
				// Applies lighting to the current scene
				void	Apply();
				
				// Accessors
				Vector3		*GetPosition() const;
				void		SetPosition(const Vector3& position);
		};
	}
}

#endif		// _CPOSITIONALLIGHT_H